#include <stdio.h>

int main()
{
    int arr[10] = {2, 1, 5, 4, 3, 6, 8, 7, 9, 10};
    int i = 0;
    int j = 0;
    int sz = sizeof(arr)/sizeof(arr[0]);
    int temp = 0;
    while(sz-1)
    {
        for (j = 0; j < sz - 1; j++)
        {
            if (arr[j] > arr[j+1])
            {
                temp = arr[j];
                arr[j] = arr[j+1];
                arr[j+1] = temp;
            }
        }
        sz--;
    }
        
    for (i = 0; i < 10; i++)
    {
        printf("%d ", arr[i]);
    }
    return 0;
}